<!doctype html>
<html>
<head>
    <meta charset="UTF-8">
    <title>后台管理</title>
    <link rel="stylesheet" type="text/css" href="__STATIC__/admin/css/common.css"/>
    <link rel="stylesheet" type="text/css" href="__STATIC__/admin/css/main.css"/>
    <script type="text/javascript" src="__STATIC__/admin/js/libs/modernizr.min.js"></script>
</head>
<style type="text/css">
    ul.pagination li{
        float: left;
    }
    div.list-page{
        width: 400px;
        margin: 0 auto;
        text-align: center;
    }
</style>
<body>
{include file="Public/top" /}
<div class="container clearfix">
    {include file="Public/left" /}
    <!--/sidebar-->
    <div class="main-wrap">

        <div class="crumb-wrap">
            <div class="crumb-list"><i class="icon-font"></i><a href="{:url('index/index')}">首页</a><span class="crumb-step">&gt;</span><span class="crumb-name">文章管理</span></div>
        </div>
        <div class="result-wrap">
            <form name="myform" id="myform" method="post">
                <div class="result-title">
                    <div class="result-list">
                        <a href="{:url('article/add')}"><i class="icon-font"></i>新增文章</a>
                    </div>
                </div>
                <div class="result-content">
                    <table class="result-tab" width="100%">
                        <tr>
                            <th>ID</th>
                            <th>文章标题</th>
                            <th>缩略图</th>
                            <th>点击量</th>
                            <th>所属栏目</th>
                            <th>发布时间</th>
                            <th>操作</th>
                        </tr>
                        {foreach name="article" item="vo"}
                        <tr>
                            <td>{$vo.id}</td>
                            <td>{$vo.title}</td>
                            <td>
                                {if condition="$vo.pic neq '' "}
                                    <img src="{$vo.pic}">
                                {else/}
                                暂无缩略图
                                {/if}
                            </td>
                            <td>{$vo.click}</td>
                             <td>{$vo.catename}</td>
                            <td>{$vo.time|date="Y-m-d",###}</td>
                            <td><a class="link-update" href="{:url('Article/edit', ['id' => $vo.id])}">修改</a>
                                <a class="link-del" onclick="return confirm('你确定要删除该栏目吗？')" href="{:url('Article/del', ['id' => $vo.id])}">删除</a>
                            </td>
                        </tr>
                        {/foreach}
                    </table>
                    <div class="list-page">{$article->render()}</div>
                </div>
            </form>
        </div>
    </div>
    <!--/main-->
</div>
</body>
</html>